package com.redpack.quick.datasource.dao;

import com.redpack.quick.datasource.entity.UserTaskInfoEntity;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.repository.CrudRepository;

import java.util.List;

/**
 * Created by shuttle on 4/2/18.
 */
public interface UserTaskInfoDao extends CrudRepository<UserTaskInfoEntity, Long> {

    Page<UserTaskInfoEntity> findByUid(String uid, Pageable pageable);

    UserTaskInfoEntity save(UserTaskInfoEntity entity);

    List<UserTaskInfoEntity> findByUidAndTaskIdAndStatusNot(String uid, String taskId, String status);

}
